package com.haxilili.demo.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.haxilili.demo.pojo.JasonReturn;
import com.haxilili.demo.service.MoveResumeService;

@Controller
@RequestMapping("move")
public class MoveResumeController {
	private static Logger log = LoggerFactory.getLogger(MoveResumeController.class);
	@Autowired
	private MoveResumeService moveResumeService;

	@RequestMapping("add")
	@ResponseBody
	public JasonReturn add(String assetsId, String outCompany, String inCompany, String arrivalDate, String fileNumber,
			String personLiable, String remember) {
		JasonReturn result = new JasonReturn();
		try {
			moveResumeService.add(assetsId, outCompany, inCompany, arrivalDate, fileNumber, personLiable, remember);
		} catch (Exception e) {
			log.warn(e.getMessage());
			result.setCode(500);
			result.setMsg(e.getMessage());
		}
		return result;
	}

}
